#!/usr/bin/env python
# -*- coding:utf-8 -*-
class Person(object):
    def __init__(self,name,age,gender,fig):
        self.name=name
        self.age=age
        self.gender=gender
        self.fight=fig

    def grassland(self):
        self.fight=self.fight-100
    def practice(self):
        self.fight=self.fight+100
    def incest(self):
        self.fight=self.fight-200
    def detail(self):
        temp= "姓名:%s ; 性别:%s ; 年龄:%s ; 战斗力:%s"  % (self.name, self.gender, self.age, self.fight)
        print temp
cang=Person('cangjj',18,'女',1000)
dong = Person('东尼木木', '男', 20, 1800)  # 创建东尼木木角色
bo = Person('波多多', '女', 19, 2500)      # 创建波多多角色

cang.incest()
dong.practice()
bo.grassland()

cang.detail()
dong.detail()
bo.detail()

